#include "prime-next.hpp"
#include "prime-ct.hpp"

#include <algorithm>

unsigned long get_next_prime_number(unsigned long number) {
    const auto pos = std::upper_bound(precomputed_primes.begin(), precomputed_primes.end(), number);
    if (pos == precomputed_primes.end()) {
        return 0;
    }
    return *pos;
}
